package com.zsx.shopping.product.vo.app;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.zsx.shopping.common.api.product.vo.SaleAttrVO;
import com.zsx.shopping.product.vo.SpuAttrVO;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.List;
import java.util.Map;

@Data
public class GoodsVO {

    private Long id;

    private String name;

    private BigDecimal price;

    private String defaultImage;

    private String displayImages;

    private List<SaleAttrVO> saleAttrs;

    private List<SpuAttrVO> spuAttrs;

    private String detailImages;

    @JsonFormat(pattern = "yyyy-MM-dd")
    private LocalDateTime createTime;

    // saleAttr attrId  attrValue_skuIds
    //            ↓           ↓
    private Map<Long, List<String>> options;
}
